Telegram Group & Telegram Channel
# پاسخ تمرین شماره 2
def add(x, y):
return x + y
def min(x, y):
return x - y
def mul(x, y):
return x * y
def div(x, y):
return x / y
oper = ''
nums = []
num1 = int(input(' عدد اول را وارد کنید: '))
nums.append(num1)
while oper != '=':
oper = input('عملگر انتخابی خود را وارد کنید (/,*,-,+,=): ')
nums.append(oper)
if oper == '=' :
print(nums, num1)
break
num2 = int(input(' عدد بعدی را وارد کنید: '))
nums.append(num2)
if oper == '+':
num1 = add(num1, num2)
elif oper == '*':
num1 = mul(num1, num2)
elif oper == '/':
num1 = div(num1, num2)
elif oper == '-':
num1 = min(num1, num2)
print(num1)



tg-me.com/python12/1307
Create:
Last Update:

# پاسخ تمرین شماره 2
def add(x, y):
return x + y
def min(x, y):
return x - y
def mul(x, y):
return x * y
def div(x, y):
return x / y
oper = ''
nums = []
num1 = int(input(' عدد اول را وارد کنید: '))
nums.append(num1)
while oper != '=':
oper = input('عملگر انتخابی خود را وارد کنید (/,*,-,+,=): ')
nums.append(oper)
if oper == '=' :
print(nums, num1)
break
num2 = int(input(' عدد بعدی را وارد کنید: '))
nums.append(num2)
if oper == '+':
num1 = add(num1, num2)
elif oper == '*':
num1 = mul(num1, num2)
elif oper == '/':
num1 = div(num1, num2)
elif oper == '-':
num1 = min(num1, num2)
print(num1)

BY پایتون / python


Warning: Undefined variable $i in /var/www/tg-me/post.php on line 283

Share with your friend now:
tg-me.com/python12/1307

View MORE
Open in Telegram


پایتون python Telegram | DID YOU KNOW?

Date: |

What is Secret Chats of Telegram

Secret Chats are one of the service’s additional security features; it allows messages to be sent with client-to-client encryption. This setup means that, unlike regular messages, these secret messages can only be accessed from the device’s that initiated and accepted the chat. Additionally, Telegram notes that secret chats leave no trace on the company’s services and offer a self-destruct timer.

The S&P 500 slumped 1.8% on Monday and Tuesday, thanks to China Evergrande, the Chinese property company that looks like it is ready to default on its more-than $300 billion in debt. Cries of the next Lehman Brothers—or maybe the next Silverado?—echoed through the canyons of Wall Street as investors prepared for the worst.

پایتون python from tw


Telegram پایتون / python
FROM USA